Repository navigation
Unit tests and refactoring to make it testable - #84
Merged
Merged
Conversation
marandaneto
commented
Oct 31, 2023
marandaneto
commented
Oct 31, 2023
marandaneto
commented
Oct 31, 2023
marandaneto
commented
Oct 31, 2023
marandaneto
commented
Oct 31, 2023
marandaneto
commented
Oct 31, 2023
marandaneto
commented
Oct 31, 2023
marandaneto
marked this pull request as ready for review
October 31, 2023 12:43
marandaneto
commented
Oct 31, 2023
Comment on lines
+31
to
+37
| dependencies: [ | ||
| "PostHog", | ||
| "Quick", | ||
| "Nimble", | ||
| "OHHTTPStubs", | ||
| .product(name: "OHHTTPStubsSwift", package: "OHHTTPStubs"), | ||
| ], |
Member
Author
There was a problem hiding this comment.
Here is what had to be done to make it work in CI, in combination with swift test instead of the xcode command for some reason.
Member
Author
There was a problem hiding this comment.
Xcode already defines those dependencies as SPM in its projects, but apparently, CI wasn't picking them up, maybe a Xcode version mismatch, an empty project worked just fine.
marandaneto
commented
Nov 2, 2023
benjackwhite
approved these changes
Nov 2, 2023
benjackwhite
left a comment
Contributor
There was a problem hiding this comment.
Mostly skimmed the tests, but the actual functional changes all seem reasonable. Mammoth effort!
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Add tests for almost every class, also has a lot of fixing found during testing.
Where should the reviewer start?
How should this be manually tested?
Any background context you want to provide?
More tests can be added specifically for
PostHogQueue, but its ok to add it later as well, its a bit complicated due to time advancing, and theURLSessioncallback approach, but I can expand it in another PR so we can unblock this PR that is getting quite big already.What are the relevant tickets?
Screenshots or screencasts (if UI/UX change)
Questions: